package com.jial08.designpatterns.decorate;

import com.jial08.designpatterns.decorate.decorator.EggDecoratorAbstract;
import com.jial08.designpatterns.decorate.decorator.HamDecoratorAbstract;
import com.jial08.designpatterns.decorate.decorator.LettuceDecoratorAbstract;
import com.jial08.designpatterns.decorate.impl.PancakeImpl;

/**
 * <p>类描述：。</p>
 *
 * @author jl
 * @version v1.0.0.1。
 * @since JDK1.8。
 * <p>创建日期：2019/10/17 下午1:07。</p>
 */
public class Demo {
	public static void main(String[] args) {
		Pancake pancake = new PancakeImpl();
		Pancake withEgg = new EggDecoratorAbstract(pancake);
		Pancake withHam = new HamDecoratorAbstract(withEgg);
		Pancake withLettuce = new LettuceDecoratorAbstract(withHam);
		withLettuce.cook();
	}
}
